package com.ruoyi.file.domain.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;
import java.util.Map;

/**
 * 上传令牌响应对象
 *
 * @author ruoyi
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema(name = "UploadTokenVO", description = "上传令牌响应对象")
public class UploadTokenVO {

    /** 临时访问密钥 */
    @Schema(description = "临时访问密钥")
    private String accessKey;

    /** 临时秘密密钥 */
    @Schema(description = "临时秘密密钥")
    private String secretKey;

    /** 会话令牌 */
    @Schema(description = "会话令牌")
    private String sessionToken;

    /** 上传端点 */
    @Schema(description = "上传端点")
    private String endpoint;

    /** 存储桶名称 */
    @Schema(description = "存储桶名称")
    private String bucketName;

    /** 区域 */
    @Schema(description = "区域")
    private String region;

    /** 过期时间戳 */
    @Schema(description = "过期时间戳")
    private Long expireTime;

    /** 预签名上传URL */
    @Schema(description = "预签名上传URL")
    private String uploadUrl;

    /** 表单数据(用于POST上传) */
    @Schema(description = "表单数据")
    private Map<String, String> formData;

    /** 最大文件大小 */
    @Schema(description = "最大文件大小(字节)")
    private Long maxFileSize;

    /** 允许的文件类型 */
    @Schema(description = "允许的文件类型")
    private List<String> allowedTypes;

    /** 文件存储路径 */
    @Schema(description = "文件存储路径")
    private String filePath;

    /** 存储配置ID */
    @Schema(description = "存储配置ID")
    private Long configId;

    /** 文件名 */
    @Schema(description = "文件名")
    private String fileName;

    /** 文件大小 */
    @Schema(description = "文件大小(字节)")
    private Long fileSize;
}
